From: YAMAMOTO Mitsuharu Date: Sun, 1 Aug 2010 16:48:15 +0000 (+0200) Subject: mouse.el: Match "mouse-2" at the beginning of the string. (Bug#6765) X-Git-Tag: archive/raspbian/1%29.2+1-2+rpi1~1^2~324^2~7088 X-Git-Url: https://dgit.raspbian.org/%22http:/www.example.com/cgi/%22https:/www.github.com/%22bookmarks:///%22http:/www.example.com/cgi/%22https:/www.github.com/%22bookmarks:/?a=commitdiff_plain;h=b34235585bd391b28ad7fc6939a537ad4089d8ab;p=emacs.git mouse.el: Match "mouse-2" at the beginning of the string. (Bug#6765) --- diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 2d524ceda39..9242524ae88 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2010-08-01 YAMAMOTO Mitsuharu + + * mouse.el (mouse-fixup-help-message): Match "mouse-2" only at the + beginning of the string. Use `string-match-p'. (Bug#6765) + 2010-08-01 Jan Djärv * cus-start.el (x-gtk-use-system-tooltips): New variable. diff --git a/lisp/mouse.el b/lisp/mouse.el index b928f636bd5..27587677513 100644 --- a/lisp/mouse.el +++ b/lisp/mouse.el @@ -879,8 +879,7 @@ at the same position." (let (mp pos) (if (and mouse-1-click-follows-link (stringp msg) - (save-match-data - (string-match "^mouse-2" msg)) + (string-match-p "\\`mouse-2" msg) (setq mp (mouse-pixel-position)) (consp (setq pos (cdr mp))) (car pos) (>= (car pos) 0)